package cn.wolfcode.crm.domain;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

@Data
public class Employee {
    @ExcelIgnore
    private Long id;
    @ExcelProperty("姓名")
    private String name;
    @ExcelIgnore
    private String password;
    @ExcelProperty("年龄")
    private Integer age;
    @ExcelProperty("邮箱")
    private String email;
    @ExcelIgnore
    private boolean admin;//基本数据类型中的布尔类型用is来做判断
    @ExcelIgnore
    private Department dept;//关联的是部门,通过部门id来取值

    //编辑回显员工时也要查询该员工的角色数据
    @ExcelIgnore
    private List<Role> roles = new ArrayList<>();

 /*   public boolean isAdmin() {
        return admin;
    }

    public void setAdmin(boolean admin) {
        this.admin = admin;
    }*/
}